package com.nmsl.statistic.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.nmsl.statistic.mapper.RetailMedicineMapper;
import com.nmsl.statistic.domain.RetailMedicine;
import com.nmsl.statistic.service.IRetailMedicineService;

/**
 * 药品零售包含药品Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-02-16
 */
@Service
public class RetailMedicineServiceImpl implements IRetailMedicineService 
{
    @Autowired
    private RetailMedicineMapper retailMedicineMapper;

    /**
     * 查询药品零售包含药品
     * 
     * @param retailMedicineId 药品零售包含药品主键
     * @return 药品零售包含药品
     */
    @Override
    public RetailMedicine selectRetailMedicineByRetailMedicineId(String retailMedicineId)
    {
        return retailMedicineMapper.selectRetailMedicineByRetailMedicineId(retailMedicineId);
    }

    /**
     * 查询药品零售包含药品列表
     * 
     * @param retailMedicine 药品零售包含药品
     * @return 药品零售包含药品
     */
    @Override
    public List<RetailMedicine> selectRetailMedicineList(RetailMedicine retailMedicine)
    {
        return retailMedicineMapper.selectRetailMedicineList(retailMedicine);
    }

    /**
     * 新增药品零售包含药品
     * 
     * @param retailMedicine 药品零售包含药品
     * @return 结果
     */
    @Override
    public int insertRetailMedicine(RetailMedicine retailMedicine)
    {
        return retailMedicineMapper.insertRetailMedicine(retailMedicine);
    }

    /**
     * 修改药品零售包含药品
     * 
     * @param retailMedicine 药品零售包含药品
     * @return 结果
     */
    @Override
    public int updateRetailMedicine(RetailMedicine retailMedicine)
    {
        return retailMedicineMapper.updateRetailMedicine(retailMedicine);
    }

    /**
     * 批量删除药品零售包含药品
     * 
     * @param retailMedicineIds 需要删除的药品零售包含药品主键
     * @return 结果
     */
    @Override
    public int deleteRetailMedicineByRetailMedicineIds(String[] retailMedicineIds)
    {
        return retailMedicineMapper.deleteRetailMedicineByRetailMedicineIds(retailMedicineIds);
    }

    /**
     * 删除药品零售包含药品信息
     * 
     * @param retailMedicineId 药品零售包含药品主键
     * @return 结果
     */
    @Override
    public int deleteRetailMedicineByRetailMedicineId(String retailMedicineId)
    {
        return retailMedicineMapper.deleteRetailMedicineByRetailMedicineId(retailMedicineId);
    }
}
